@extends('admin.master')

@section('css')
    <link rel="stylesheet" type="text/css" href="/css/ga-embed.css">
    <style>
        .genjin {
            width: 800px;
            height: 500px;
            background-color: #6B8682;
            border-radius: 10px;
            position: fixed;
            padding: 20px;
            bottom: 0;
            right: 0;
        }

        .genjin-title {
            font-weight: bold;
            width: 720px;
            float: left;
            font-size: 20px;
            text-align: center;
            color: #FFF;
        }

        th {
            font-weight: bold !important;
        }

        .float-label {
            position: fixed;
            top: 50%;
            right: -10px;
            width: 40px;
            height: 120px;
            border-radius: 10px;
            background-color: #0a9dc7;
            color: #FFF;
            font-weight: bold;
            font-size: 16px;
            padding: 12px;
            cursor: pointer;
        }

    </style>
@stop

@section('content')
    <div style="padding:20px">
        @foreach ($company as $k=>$com)
            <div class="panel @if ($k == 0) panel-success @else panel-danger @endif col-md-5"
                 @if ($k == 0)style="margin-right:90px;margin-left:40px;"@endif>
                <h3 class="panel-title" style="color:#000">{{$com->title_type}}</h3>
                <div class="panel-body">
                    {{$com->title}}
                </div>
                <div class="panel-footer" style="text-align:right">发布时间：{{$com->updated_at}}</div>
            </div>
        @endforeach
    </div>
@stop
@section('javascript')
    <script>
        $(document).ready(function () {
            $(".float-label").hover(function () {
                $(this).animate({right: '0'});
            }, function () {
                $(this).animate({right: '-10px'});
            }).click(function () {
                $(".genjin").animate({right: '0'}, 500);
            });

            $('#close-panel').click(function () {
                $(".genjin").animate({right: '-800px'}, 500);
            });
        })

    </script>
@stop
